<?
if($canCreate){
?>
<a class="btn" href="<?php echo $current?>adddata/">Create Forum</a>
<br />
<?
}
?>
<div class="clear20"></div>
<table class="table table-striped table-bordered table-condensed"> <!-- cellspacing='0' is important, must stay -->

	<!-- Table Header -->
	<thead>
		<tr>
			<th style="width:30%">Forum</th>
			<th style="width:20%">Comment</th>
			<th style="width:25%">Post By</th>
			<th style="width:25%">Last Post By</th>
			
		</tr>
	</thead>
	<!-- Table Header -->

	<!-- Table Body -->
	<tbody>

		<?
		
		foreach($dataList as $in=>$val){
		?>
			<tr>
				<td valign="top">
					<?
					if($val->isPin=="Y"){
					?>
					<img style="width:30px;height:auto" src="<?php echo base_url()?>asset/images/pin.gif" />
					<?
					}
					
					?>
					<img style="width:30px;height:auto" src="<?php echo base_url()?>asset/images/<?php echo $val->forumType?>.gif" />
					
					
					<a href="<?php echo $current?>view/<?php echo $val->fID?>">
					<i class="fa fa-external-link"></i>
					<?php echo $val->title?></a></td>
				<td align="right">
					Comment: <?php echo $val->numOfComment?>
					<br />
					View: <?php echo $val->numOfView?>
				</td>
				<td alig="right"><?php echo $val->postname?>
					<br />post date <?php echo $val->createOn?>
				</td>
				<td alig="right"><?php echo $val->lastPostName?>
					<br />update date <?php echo $val->updateOn?>
				</td>
				
			</tr>
		<?
		}
		?>

	</tbody>
	<!-- Table Body -->

</table>
<div class=" pagination">
        <ul class="pagination">
            <?
            echo $pagination->create_links();
            ?>
        </ul>    
    </div>
    